package com.skytech.tax.customsdatawarehouse.singlewindow.processtrade.manual.resource;

import com.skytech.tax.customsdatawarehouse.singlewindow.processtrade.manual.domain.service.ManualGoodsService;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

/**
 * @author Lianhong
 * @since 2021/11/11
 */
@RestController
@RequestMapping("/single-window/process-trade/manual/goods")
public class ManualGoodsResource {

    @Resource
    private ManualGoodsService manualGoodsService;

    @GetMapping("/halo")
    public String halo(@RequestParam String name) {
        return "halo, " + name;
    }

    /**
     * 保存加工贸易手册单耗
     *
     * @param con 加工贸易手册单耗
     */
    @PostMapping("con")
    public String saveCon(@RequestBody String con) {
        return manualGoodsService.saveCon(con);
    }

    /**
     * 保存加工贸易手册成品
     *
     * @param exg 加工贸易手册成品
     */
    @PostMapping("exg")
    public String saveExg(@RequestBody String exg) {
        return manualGoodsService.saveExg(exg);
    }

    /**
     * 保存加工贸易手册料件
     *
     * @param img 加工贸易手册料件
     */
    @PostMapping("img")
    public String saveImg(@RequestBody String img) {
        return manualGoodsService.saveImg(img);
    }


}
